//
//  orderTableViewCell.m
//  uniform
//
//  Created by Apple on 15/8/28.
//  Copyright (c) 2015年 giuseppe. All rights reserved.
//

#import "orderTableViewCell.h"

@implementation orderTableViewCell

- (void)awakeFromNib {
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

- (id)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self)
    {
        [self addSubviews];
    }
    return self;
}
-(void)addSubviews{
    
    //主体界面
    self.goodsImageView = [[UIImageView alloc]init];
    [self addSubview:self.goodsImageView];
    
    
    self.nameLabel = [[UILabel alloc]init];
    [self addSubview:self.nameLabel];
    
    
    self.orderNumberLabel = [[UILabel alloc]init];
    self.orderNumberLabel.font = [UIFont systemFontOfSize:13];
    self.orderNumberLabel.textColor = [UIColor lightGrayColor];
    [self addSubview:self.orderNumberLabel];
    
    
    self.priceLabel = [[UILabel alloc]init];
    self.priceLabel.textColor = mainColor;
    [self addSubview:self.priceLabel];
    
    
    self.goodsNumberLabel = [[UILabel alloc]init];
    self.goodsNumberLabel.backgroundColor = mainColor;
    self.goodsNumberLabel.textColor = [UIColor whiteColor];
    self.goodsNumberLabel.adjustsFontSizeToFitWidth = YES;
    self.goodsNumberLabel.textAlignment = NSTextAlignmentCenter;
    [self addSubview:self.goodsNumberLabel];
    
    
    //红色button
    self.confirmReceivedButton = [UIButton buttonWithType:UIButtonTypeCustom];
    [self.confirmReceivedButton setImage:[UIImage imageNamed:@"confirmReceived"] forState:UIControlStateNormal];
    [self addSubview:self.confirmReceivedButton];
    
    
    self.payButton = [UIButton buttonWithType:UIButtonTypeCustom];
    [self.payButton setImage:[UIImage imageNamed:@"pay"] forState:UIControlStateNormal];
    [self addSubview:self.payButton];
    
    
    self.progressSearchButton = [UIButton buttonWithType:UIButtonTypeCustom];
    [self.progressSearchButton setImage:[UIImage imageNamed:@"progressSearch"] forState:UIControlStateNormal];
    [self addSubview:self.progressSearchButton];
    
    
    self.evaluationButton = [UIButton buttonWithType:UIButtonTypeCustom];
    [self.evaluationButton setImage:[UIImage imageNamed:@"evaluation"] forState:UIControlStateNormal];
    [self addSubview:self.evaluationButton];
    
    
    //灰色button
    self.LogisticsButton = [UIButton buttonWithType:UIButtonTypeCustom];
    [self.LogisticsButton setImage:[UIImage imageNamed:@"searchLogistics"] forState:UIControlStateNormal];
    [self addSubview:self.LogisticsButton];
    
    
    self.returnButton = [UIButton buttonWithType:UIButtonTypeCustom];
    [self.returnButton setImage:[UIImage imageNamed:@"returnGoods"] forState:UIControlStateNormal];
    [self addSubview:self.returnButton];
    
    
    self.exchangesButton = [UIButton buttonWithType:UIButtonTypeCustom];
    [self.exchangesButton setImage:[UIImage imageNamed:@"exchangeGoods"] forState:UIControlStateNormal];
    [self addSubview:self.exchangesButton];


    //退换货标志
    self.returnTitleLabel = [[UILabel alloc]init];
    self.returnTitleLabel.adjustsFontSizeToFitWidth = YES;
    self.returnTitleLabel.backgroundColor = [UIColor lightGrayColor];
    self.returnTitleLabel.textColor = [UIColor whiteColor];
    self.returnTitleLabel.layer.masksToBounds = YES;
    self.returnTitleLabel.layer.cornerRadius = 3;
    self.returnTitleLabel.text = @"退货";
    self.returnTitleLabel.textAlignment = NSTextAlignmentCenter;
    [self addSubview:self.returnTitleLabel];
    
    self.exchangeTitleLabel = [[UILabel alloc]init];
    self.exchangeTitleLabel.adjustsFontSizeToFitWidth = YES;
    self.exchangeTitleLabel.backgroundColor = mainColor;
    self.exchangeTitleLabel.textColor = [UIColor whiteColor];
    self.exchangeTitleLabel.layer.masksToBounds = YES;
    self.exchangeTitleLabel.layer.cornerRadius = 3;
    self.exchangeTitleLabel.text = @"换货";
    self.exchangeTitleLabel.textAlignment = NSTextAlignmentCenter;
    [self addSubview:self.exchangeTitleLabel];
    

}
- (void)layoutSubviews {
    
    
    
}






@end
